import torch
print(f'PyTorch版本: {torch.__version__}')
print(f'CUDA可用: {torch.cuda.is_available()}')
if torch.cuda.is_available():
    print(f'CUDA版本: {torch.version.cuda}')

# 检查GDAL
try:
    from osgeo import gdal
    print(f'GDAL版本: {gdal.__version__}')
except ImportError:
    print('GDAL未安装')

# 检查SAM2
try:
    import sam2
    print('SAM2已安装')
except ImportError:
    print('SAM2未安装')